﻿using System;
using Microsoft.Win32;

namespace DotNetNexusSpam
{
    class RegistryUtil
    {
        public static string Read(string key, string name) {
            RegistryKey regKey = Registry.LocalMachine.OpenSubKey(key, false);
            string regvalue = "";
            if (regKey != null)
            {
                regvalue = regKey.GetValue(name).ToString();
                regKey.Close();
            }
            return regvalue;
        }
    }
}
